<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
  <title>tango.time.chrono.Calendar</title>
  <link href="./css/style.css" rel="stylesheet" type="text/css"/>
  <!-- <link href="./img/icon.png" rel="icon" type="image/png"/> -->
  <script type="text/javascript" src="./js/jquery.js"></script>
  <script type="text/javascript" src="./js/modules.js"></script>
  <script type="text/javascript" src="./js/quicksearch.js"></script>
  <script type="text/javascript" src="./js/navigation.js"></script>
  <!--<script type="text/javascript" src="./js/jquery.treeview.js"></script>-->
  <script type="text/javascript">
    var g_moduleFQN = "tango.time.chrono.Calendar";
  </script>
  
</head>
<body>
<div id="content">
  <h1><a href="./htmlsrc/tango.time.chrono.Calendar.html" class="symbol">tango.time.chrono.Calendar</a></h1>
  
<p class="sec_header">License:</p>BSD style: see <a href="http://www.dsource.org/projects/tango/wiki/LibraryLicense">license.txt</a>
<p class="sec_header">Version:</p>Mid 2005: Initial release
                        Apr 2007: reshaped
<p class="sec_header">Author:</p>John Chapman, Kris
<dl>
<dt class="decl">class <a class="symbol _class" name="Calendar" href="./htmlsrc/tango.time.chrono.Calendar.html#L30" kind="class" beg="30" end="472">Calendar</a>; <span class="attrs">[<span class="prot">public</span>, <span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L30">#</a></dt>
<dd class="ddef">
<div class="summary"><a name="_Calendar"></a>
 Represents time in week, month and year divisions.</div>
<p class="sec_header">Remarks:</p>Calendar is the abstract base class for the following Calendar implementations: 
   <a href="#Gregorian">Gregorian</a>, <a href="#Hebrew">Hebrew</a>, <a href="#Hijri">Hijri</a>,
   <a href="#Japanese">Japanese</a>, <a href="#Korean">Korean</a>, <a href="#Taiwan">Taiwan</a> and
   <a href="#ThaiBuddhist">ThaiBuddhist</a>.
<dl>
<dt class="decl"><a class="symbol _enum" name="Calendar.enum" href="./htmlsrc/tango.time.chrono.Calendar.html#L35" kind="enum" beg="35" end="35">enum</a>; <span class="attrs">[<span class="prot">package</span>]</span> <a title="Permalink to this symbol" href="#Calendar.enum" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L35">#</a></dt>
<dd class="ddef">
<div class="summary">Indicates the current era of the calendar.</div>
</dd>
<dt class="decl">Date <a class="symbol _function" name="Calendar.toDate" href="./htmlsrc/tango.time.chrono.Calendar.html#L91" kind="function" beg="91" end="96">toDate</a><span class="params">(Time <em>time</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.toDate" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L91">#</a></dt>
<dd class="ddef">
<div class="summary">Get the components of a Time structure using the rules of the
 calendar.  This is useful if you want more than one of the given
 components.  Note that this doesn't handle the time of day, as that
 is calculated directly from the Time struct.</div>
The default implemenation is to call all the other accessors
 directly, a derived class may override if it has a more efficient
 method.</dd>
<dt class="decl">void <a class="symbol _function" name="Calendar.split" href="./htmlsrc/tango.time.chrono.Calendar.html#L108" kind="function" beg="108" end="116">split</a><span class="params">(Time <em>time</em>, ref uint <em>year</em>, ref uint <em>month</em>, ref uint <em>day</em>, ref uint <em>doy</em>, ref uint <em>dow</em>, ref uint <em>era</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.split" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L108">#</a></dt>
<dd class="ddef">
<div class="summary">Get the components of a Time structure using the rules of the
 calendar.  This is useful if you want more than one of the given
 components.  Note that this doesn't handle the time of day, as that
 is calculated directly from the Time struct.</div>
The default implemenation is to call all the other accessors
 directly, a derived class may override if it has a more efficient
 method.</dd>
<dt class="decl">Time <a class="symbol _function" name="Calendar.toTime" href="./htmlsrc/tango.time.chrono.Calendar.html#L130" kind="function" beg="130" end="133">toTime</a><span class="params">(uint <em>year</em>, uint <em>month</em>, uint <em>day</em>, uint <em>hour</em>, uint <em>minute</em>, uint <em>second</em>, uint <em>millisecond</em> = 0)</span>; <a title="Permalink to this symbol" href="#Calendar.toTime" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L130">#</a></dt>
<dd class="ddef">
<div class="summary">Returns a Time value set to the specified date and time in the current era.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr>
<tr><td><em>month</em></td><td>An integer representing the _month.</td></tr>
<tr><td><em>day</em></td><td>An integer representing the _day.</td></tr>
<tr><td><em>hour</em></td><td>An integer representing the _hour.</td></tr>
<tr><td><em>minute</em></td><td>An integer representing the _minute.</td></tr>
<tr><td><em>second</em></td><td>An integer representing the _second.</td></tr>
<tr><td><em>millisecond</em></td><td>An integer representing the _millisecond.</td></tr></table>
<p class="sec_header">Returns:</p>The Time set to the specified date and time.</dd>
<dt class="decl">Time <a class="symbol _function" name="Calendar.toTime:2" href="./htmlsrc/tango.time.chrono.Calendar.html#L141" kind="function" beg="141" end="144">toTime</a><span class="params">(Date <em>d</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.toTime:2" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L141">#</a></dt>
<dd class="ddef">
<div class="summary">Returns a Time value for the given Date, in the current era</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>date</em></td><td>a representation of the Date</td></tr></table>
<p class="sec_header">Returns:</p>The Time set to the specified date.</dd>
<dt class="decl">Time <a class="symbol _function" name="Calendar.toTime:3" href="./htmlsrc/tango.time.chrono.Calendar.html#L152" kind="function" beg="152" end="155">toTime</a><span class="params">(DateTime <em>dt</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.toTime:3" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L152">#</a></dt>
<dd class="ddef">
<div class="summary">Returns a Time value for the given DateTime, in the current era</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>dt</em></td><td>a representation of the date and time</td></tr></table>
<p class="sec_header">Returns:</p>The Time set to the specified date and time.</dd>
<dt class="decl">Time <a class="symbol _function" name="Calendar.toTime:4" href="./htmlsrc/tango.time.chrono.Calendar.html#L164" kind="function" beg="164" end="167">toTime</a><span class="params">(Date <em>d</em>, TimeOfDay <em>t</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.toTime:4" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L164">#</a></dt>
<dd class="ddef">
<div class="summary">Returns a Time value for the given Date and TimeOfDay, in the current era</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>d</em></td><td>a representation of the date</td></tr>
<tr><td><em>t</em></td><td>a representation of the day time</td></tr></table>
<p class="sec_header">Returns:</p>The Time set to the specified date and time.</dd>
<dt class="decl">Time <a class="symbol _function" name="Calendar.toTime:5" href="./htmlsrc/tango.time.chrono.Calendar.html#L182" kind="function" beg="182" end="182">toTime</a><span class="params">(uint <em>year</em>, uint <em>month</em>, uint <em>day</em>, uint <em>hour</em>, uint <em>minute</em>, uint <em>second</em>, uint <em>millisecond</em>, uint <em>era</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.toTime:5" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L182">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns a Time value set to the specified date and time in the specified _era.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr>
<tr><td><em>month</em></td><td>An integer representing the _month.</td></tr>
<tr><td><em>day</em></td><td>An integer representing the _day.</td></tr>
<tr><td><em>hour</em></td><td>An integer representing the _hour.</td></tr>
<tr><td><em>minute</em></td><td>An integer representing the _minute.</td></tr>
<tr><td><em>second</em></td><td>An integer representing the _second.</td></tr>
<tr><td><em>millisecond</em></td><td>An integer representing the _millisecond.</td></tr>
<tr><td><em>era</em></td><td>An integer representing the _era.</td></tr></table>
<p class="sec_header">Returns:</p>A Time set to the specified date and time.</dd>
<dt class="decl">DayOfWeek <a class="symbol _function" name="Calendar.getDayOfWeek" href="./htmlsrc/tango.time.chrono.Calendar.html#L189" kind="function" beg="189" end="189">getDayOfWeek</a><span class="params">(Time <em>time</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getDayOfWeek" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L189">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the day of the week in the specified Time.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>time</em></td><td>A Time value.</td></tr></table>
<p class="sec_header">Returns:</p>A DayOfWeek value representing the day of the week of time.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getDayOfMonth" href="./htmlsrc/tango.time.chrono.Calendar.html#L196" kind="function" beg="196" end="196">getDayOfMonth</a><span class="params">(Time <em>time</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getDayOfMonth" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L196">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the day of the month in the specified Time.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>time</em></td><td>A Time value.</td></tr></table>
<p class="sec_header">Returns:</p>An integer representing the day of the month of time.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getDayOfYear" href="./htmlsrc/tango.time.chrono.Calendar.html#L203" kind="function" beg="203" end="203">getDayOfYear</a><span class="params">(Time <em>time</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getDayOfYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L203">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the day of the year in the specified Time.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>time</em></td><td>A Time value.</td></tr></table>
<p class="sec_header">Returns:</p>An integer representing the day of the year of time.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getMonth" href="./htmlsrc/tango.time.chrono.Calendar.html#L210" kind="function" beg="210" end="210">getMonth</a><span class="params">(Time <em>time</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getMonth" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L210">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the month in the specified Time.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>time</em></td><td>A Time value.</td></tr></table>
<p class="sec_header">Returns:</p>An integer representing the month in time.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getYear" href="./htmlsrc/tango.time.chrono.Calendar.html#L217" kind="function" beg="217" end="217">getYear</a><span class="params">(Time <em>time</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L217">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the year in the specified Time.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>time</em></td><td>A Time value.</td></tr></table>
<p class="sec_header">Returns:</p>An integer representing the year in time.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getEra" href="./htmlsrc/tango.time.chrono.Calendar.html#L224" kind="function" beg="224" end="224">getEra</a><span class="params">(Time <em>time</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getEra" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L224">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the era in the specified Time.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>time</em></td><td>A Time value.</td></tr></table>
<p class="sec_header">Returns:</p>An integer representing the ear in time.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getDaysInMonth" href="./htmlsrc/tango.time.chrono.Calendar.html#L233" kind="function" beg="233" end="236">getDaysInMonth</a><span class="params">(uint <em>year</em>, uint <em>month</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.getDaysInMonth" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L233">#</a></dt>
<dd class="ddef">
<div class="summary">Returns the number of days in the specified _year and _month of the current era.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr>
<tr><td><em>month</em></td><td>An integer representing the _month.</td></tr></table>
<p class="sec_header">Returns:</p>The number of days in the specified _year and _month of the current era.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getDaysInMonth:2" href="./htmlsrc/tango.time.chrono.Calendar.html#L246" kind="function" beg="246" end="246">getDaysInMonth</a><span class="params">(uint <em>year</em>, uint <em>month</em>, uint <em>era</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getDaysInMonth:2" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L246">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the number of days in the specified _year and _month of the specified _era.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr>
<tr><td><em>month</em></td><td>An integer representing the _month.</td></tr>
<tr><td><em>era</em></td><td>An integer representing the _era.</td></tr></table>
<p class="sec_header">Returns:</p>The number of days in the specified _year and _month of the specified _era.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getDaysInYear" href="./htmlsrc/tango.time.chrono.Calendar.html#L253" kind="function" beg="253" end="256">getDaysInYear</a><span class="params">(uint <em>year</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.getDaysInYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L253">#</a></dt>
<dd class="ddef">
<div class="summary">Returns the number of days in the specified _year of the current era.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr></table>
<p class="sec_header">Returns:</p>The number of days in the specified _year in the current era.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getDaysInYear:2" href="./htmlsrc/tango.time.chrono.Calendar.html#L265" kind="function" beg="265" end="265">getDaysInYear</a><span class="params">(uint <em>year</em>, uint <em>era</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getDaysInYear:2" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L265">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the number of days in the specified _year of the specified _era.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr>
<tr><td><em>era</em></td><td>An integer representing the _era.</td></tr></table>
<p class="sec_header">Returns:</p>The number of days in the specified _year in the specified _era.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getMonthsInYear" href="./htmlsrc/tango.time.chrono.Calendar.html#L272" kind="function" beg="272" end="275">getMonthsInYear</a><span class="params">(uint <em>year</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.getMonthsInYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L272">#</a></dt>
<dd class="ddef">
<div class="summary">Returns the number of months in the specified _year of the current era.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr></table>
<p class="sec_header">Returns:</p>The number of months in the specified _year in the current era.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getMonthsInYear:2" href="./htmlsrc/tango.time.chrono.Calendar.html#L284" kind="function" beg="284" end="284">getMonthsInYear</a><span class="params">(uint <em>year</em>, uint <em>era</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.getMonthsInYear:2" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L284">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, returns the number of months in the specified _year of the specified _era.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr>
<tr><td><em>era</em></td><td>An integer representing the _era.</td></tr></table>
<p class="sec_header">Returns:</p>The number of months in the specified _year in the specified _era.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.getWeekOfYear" href="./htmlsrc/tango.time.chrono.Calendar.html#L294" kind="function" beg="294" end="332">getWeekOfYear</a><span class="params">(Time <em>time</em>, WeekRule <em>rule</em>, DayOfWeek <em>firstDayOfWeek</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.getWeekOfYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L294">#</a></dt>
<dd class="ddef">
<div class="summary">Returns the week of the year that includes the specified Time.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>time</em></td><td>A Time value.</td></tr>
<tr><td><em>rule</em></td><td>A WeekRule value defining a calendar week.</td></tr>
<tr><td><em>firstDayOfWeek</em></td><td>A DayOfWeek value representing the first day of the week.</td></tr></table>
<p class="sec_header">Returns:</p>An integer representing the week of the year that includes the date in time.</dd>
<dt class="decl">bool <a class="symbol _function" name="Calendar.isLeapYear" href="./htmlsrc/tango.time.chrono.Calendar.html#L339" kind="function" beg="339" end="342">isLeapYear</a><span class="params">(uint <em>year</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.isLeapYear" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L339">#</a></dt>
<dd class="ddef">
<div class="summary">Indicates whether the specified _year in the current era is a leap _year.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr></table>
<p class="sec_header">Returns:</p>true is the specified _year is a leap _year; otherwise, false.</dd>
<dt class="decl">bool <a class="symbol _function" name="Calendar.isLeapYear:2" href="./htmlsrc/tango.time.chrono.Calendar.html#L350" kind="function" beg="350" end="350">isLeapYear</a><span class="params">(uint <em>year</em>, uint <em>era</em>)</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.isLeapYear:2" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L350">#</a></dt>
<dd class="ddef">
<div class="summary">When overridden, indicates whether the specified _year in the specified _era is a leap _year.</div>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>year</em></td><td>An integer representing the _year.</td></tr></table>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>era</em></td><td>An integer representing the _era.</td></tr></table>
<p class="sec_header">Returns:</p>true is the specified _year is a leap _year; otherwise, false.</dd>
<dt class="decl">uint[] <a class="symbol _function" name="Calendar.eras" href="./htmlsrc/tango.time.chrono.Calendar.html#L356" kind="function" beg="356" end="356">eras</a><span class="params">()</span>; <span class="attrs">[<span class="stc">abstract</span>]</span> <a title="Permalink to this symbol" href="#Calendar.eras" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L356">#</a></dt>
<dd class="ddef">
<div class="summary"><i>Property.</i> When overridden, retrieves the list of eras in the current calendar.</div>
<p class="sec_header">Returns:</p>An integer array representing the eras in the current calendar.</dd>
<dt class="decl">uint <a class="symbol _function" name="Calendar.id" href="./htmlsrc/tango.time.chrono.Calendar.html#L362" kind="function" beg="362" end="365">id</a><span class="params">()</span>; <a title="Permalink to this symbol" href="#Calendar.id" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L362">#</a></dt>
<dd class="ddef">
<div class="summary"><i>Property.</i> Retrieves the identifier associated with the current calendar.</div>
<p class="sec_header">Returns:</p>An integer representing the identifier of the current calendar.</dd>
<dt class="decl">Time <a class="symbol _function" name="Calendar.addMonths" href="./htmlsrc/tango.time.chrono.Calendar.html#L385" kind="function" beg="385" end="440">addMonths</a><span class="params">(Time <em>t</em>, int <em>nMonths</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.addMonths" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L385">#</a></dt>
<dd class="ddef">
<div class="summary">Returns a new Time with the specified number of months added.  If
 the months are negative, the months are subtracted.</div>
The default implementation uses information provided by the
 calendar to calculate the correct time to add.  Derived classes may
 override if there is a more optimized method.
<p class="bl"/>
 Note that the generic method does not take into account crossing
 era boundaries.  Derived classes may support this.
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>t</em></td><td>A time to add the months to</td></tr></table>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>nMonths</em></td><td>The number of months to add.  This can be
 negative.</td></tr></table>
<p class="sec_header">Returns:</p>A Time that represents the provided time with the number
 of months added.</dd>
<dt class="decl">Time <a class="symbol _function" name="Calendar.addYears" href="./htmlsrc/tango.time.chrono.Calendar.html#L458" kind="function" beg="458" end="466">addYears</a><span class="params">(Time <em>t</em>, int <em>nYears</em>)</span>; <a title="Permalink to this symbol" href="#Calendar.addYears" class="symlink">¶</a><a title="Go to the HTML source file" class="srclink" href="./htmlsrc/tango.time.chrono.Calendar.html#L458">#</a></dt>
<dd class="ddef">
<div class="summary">Add the specified number of years to the given Time.</div>
The generic algorithm uses information provided by the abstract
 methods.  Derived classes may re-implement this in order to
 optimize the algorithm
<p class="bl"/>
 Note that the generic algorithm does not take into account crossing
 era boundaries.  Derived classes may support this.
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>t</em></td><td>A time to add the years to</td></tr></table>
<p class="sec_header">Params:</p>
<table class="params">
<tr><td><em>nYears</em></td><td>The number of years to add.  This can be negative.</td></tr></table>
<p class="sec_header">Returns:</p>A Time that represents the provided time with the number
 of years added.</dd></dl></dd></dl>
</div>
<div id="footer">
  <p>Copyright (c) 2005 John Chapman. All rights reserved</p>
  <p>Page generated by <a href="http://code.google.com/p/dil">dil</a> on Fri Dec 26 04:04:12 2008. Rendered by <a href="http://code.google.com/p/dil/wiki/Kandil">kandil</a>.</p>
</div>
</body>
</html>